<!doctype html>
<html lang="en">
<head>
  <meta charset="utf-8" />
  <script src="../../../platform/platform.js"></script>
  <script src="polymer-element.js"></script>
  <script src="elements.js"></script>
</head>
<body>
  
  <x-foo></x-foo>  
  <hr>
  
  <x-bar></x-bar>
  <hr>
  
  <x-zot></x-zot>
  <hr>

  <x-baz></x-baz>
  <hr>

  <x-quux></x-quux>
  <hr

  <!-- preloaded external script -->
  <polymer-element name="x-foo">
    <template>
      Hello Light World
    </template>
  </polymer-element>
  
  <!-- external script w/templating override -->
  <polymer-element name="x-bar" extends="x-foo">
    <template>
      Hello Lighter World [<shadow></shadow>]
    </template>
  </polymer-element>

  <!-- no script -->
  <polymer-element name="x-zot" extends="x-foo">
    <template>
      Hello Lighter World [<shadow></shadow>]
    </template>
  </polymer-element>

  <!-- inline script -->
  <polymer-element name="x-baz" extends="x-zot">
    <script>
      Polymer('x-baz', {
        ready: function() {
          this.style.padding = '4px';
          this.style.backgroundColor = 'tomato';
          this.__proto__.__proto__.ready.call(this);
        }
      });
    </script>
  </polymer-element>

  <!-- inline external script -->
  <polymer-element name="x-quux" extends="x-zot">
    <script src="x-quux.js"></script>
  </polymer-element>

  <script>
    addEventListener("WebComponentsReady", function() {
      CustomElements.upgradeDocument(document);
    });
  </script>
</body>
</html>
